<?php

/**
 * 帐套公司仓库
 * @author wangwx 2015-5-22
 */
namespace common\repositories\myhtsq;
use common\repositories\BaseRepository;
use common\entities\myhtsq\ContractAccountCompanyEntity;
class ContractAccountCompanyRepository extends BaseRepository{

	/**
	 * 构造方法
	 * @param unknown $config (optional)
	 */
	public function __construct($config = [])
	{
		parent::__construct($config);
	}
	
	/**
	 * 根据性质id,获取公司列表
	 * @param string $propertyId 性质id
	 * @return array
	 */
	public static function getContractAccountCompanyListByPropertyId($propertyId) {
		return ContractAccountCompanyEntity::find()->where('find_in_set(:propertyId,property_id)')->params([':propertyId'=>$propertyId])->all();
	}

	
	
}